package fr.neticar.webremoteclient.client;

import com.google.gwt.user.client.rpc.IsSerializable;

public class EventType implements IsSerializable {

    public static final EventType ON_MOUSE_DOWN = new EventType(1);

    public static final EventType ON_MOUSE_UP = new EventType(2);

    public static final EventType ON_MOUSE_MOVE = new EventType(3);
    
    public static final EventType ON_KEY_DOWN = new EventType(4);

    public static final EventType ON_KEY_UP = new EventType(5);
    
    public static final EventType ON_KEY_TYPE = new EventType(6);

    private int type;

    
    
    private EventType(int type) {
        this.type = type;
    }
    
    public EventType() {
        
    }
    
    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }

    public boolean equals(Object obj) {
        if (!(obj instanceof EventType)) {
            return false;
        }
        EventType toCompate = (EventType) obj;
        return (toCompate.type == type);
    }
}
